package android.support.graphics.drawable;

import android.graphics.Path;
import android.util.Log;

import lombok.Data;

/**
 * Created by lijun on 2017/11/27.
 */

@Data
public class ViewUtils {
    private final static String ERROR = "Error";
    private Path path;

    public ViewUtils() {

    }

    public Path getLetterPath(String letterPath) {
        if (letterPath.isEmpty()) {
            Log.e(ERROR, "the letter path is null");
            return null;
        }
        Path path = new Path();
        try {
            path = PathParser.createPathFromPathData(letterPath);
        } catch (Exception e) {
            Log.e(ERROR, " path parser error: " + e.getMessage());
        }
        return path;
    }

}
